<?php

use think\migration\Migrator;

class UserLevel extends Migrator
{

    public function change()
    {
        $table = $this->table('user');
        $table->addColumn('level', 'integer', ['limit' => 11,'comment' => '等级','default' => 1]);
        $table->addColumn('exp', 'integer', ['limit' => 11,'comment' => '经验','default' => 5]);
        $table->addColumn('title', 'string', ['limit' => 32,'comment' => '头衔','default' => null]);
        $table->update();
    }
}
